//
//  ConsultDetailViewControllerModel.m
//  110
//
//  Created by lanou on 16/4/11.
//  Copyright © 2016年 乔砥. All rights reserved.
//

#import "ConsultDetailViewControllerModel.h"
#import "NSString+Html.h"
@implementation ConsultDetailViewControllerModel

-(void)setValue:(id)value forUndefinedKey:(NSString *)key
{
    if ([key isEqualToString:@"content"]) {
        NSString *newString = [NSString importStyleWithHtmlString:value];
        [self setValue:newString forKey:@"content"];
    }
    
}


+(NSMutableArray *)getData:(NSDictionary *)dic
{
    
    NSMutableArray *modelArray = [NSMutableArray array];
    NSArray *itemsArray = dic[@"items"];
    for (NSDictionary *dic in itemsArray)
    {
        ConsultDetailViewControllerModel *model = [[ConsultDetailViewControllerModel alloc]init];
        [model setValuesForKeysWithDictionary:dic];
        [modelArray addObject:model];
        NSLog(@"++%@",model.content);
        
    }
    
    return modelArray;
    
    
}





@end
